export default [
  {
    path: '/user',
    component: '../layouts/UserLayout',
    routes: [
      {
        name: 'login',
        path: '/user/login',
        component: './User/Login',
      },
      {
        name: 'register',
        icon: 'smile',
        path: '/user/register',
        component: './User/UserRegister',
      },
    ],
  },
  {
    path: '/',
    component: '../layouts/SecurityLayout',
    routes: [
      {
        path: '/',
        component: '../layouts/BasicLayout',
        routes: [
          {
            path: '/',
            redirect: '/welcome',
          },
          {
            path: '/welcome',
            name: 'welcome',
            icon: 'smile',
            component: './Welcome',
          },
          {
            path: '/admin',
            name: 'admin',
            icon: 'crown',
            component: './Admin',
            authority: ['admin'],
            routes: [
              {
                path: '/admin/sub-page',
                name: 'sub-page',
                icon: 'smile',
                component: './Welcome',
                authority: ['admin'],
              },
            ],
          },
          {
            name: 'list.table-list',
            icon: 'table',
            path: '/list',
            component: './ListTableList',
          },
          {
            name: 'system',
            icon: 'table',
            path: 'system',
            routes: [
              {
                name: 'menu',
                component: './System/Menu',
                path: '/system/menu',
                icon: 'table',
                access: 'system:menu:list',
              },
              {
                name: 'role',
                icon: 'smile',
                path: '/system/role',
                component: './System/Role',
                access: 'system:role:list',
              },
              {
                name: 'dict',
                icon: 'smile',
                path: 'dict',
                component: './System/Dict',
                access: 'system:dict:list',
              },
              {
                name: 'dictData',
                icon: 'smile',
                path: '/system/dict/data/:dictId',
                component: './System/DictData',
                access: 'system:dictdata:list',
              },
              {
                name: 'dept',
                icon: 'smile',
                path: '/system/dept',
                component: './System/Dept',
                access: 'system:dept:list',
              },
              {
                name: 'post',
                icon: 'smile',
                path: '/system/post',
                component: './System/Post',
                access: 'system:post:list',
              },
              {
                name: 'user',
                icon: 'smile',
                path: '/system/user',
                component: './System/User',
                access: 'system:user:list',
              },
              {
                name: 'log',
                icon: 'smile',
                path: 'log',
                routes: [
                  {
                    name: 'operlog',
                    icon: 'smile',
                    path: 'operlog',
                    component: './System/OperLog',
                    access: 'monitor:operlog:list',
                  },
                  {
                    name: 'logininfor',
                    icon: 'smile',
                    path: 'logininfor',
                    component: './System/LoginInfor',
                    access: 'monitor:logininfor:list',
                  },
                ],
              },
              {
                name: '查询表格',
                icon: 'smile',
                path: '/system/notice',
                component: './System/Notice',
              },
              {
                component: './404',
              },
            ],
          },
          {
            name: 'monitor',
            icon: 'smile',
            path: 'monitor',
            routes: [
              {
                name: 'online',
                component: './Monitor/Online',
                path: 'online',
                icon: 'table',
              },
              {
                name: 'server',
                icon: 'smile',
                path: '/monitor/server',
                component: './Monitor/Server',
              },
            ],
          },
          {
            name: 'dashboard',
            icon: 'smile',
            path: '/dashboardanalysis',
            component: './DashboardAnalysisTwo',
          },
          {
            name: 'accountsettings',
            icon: 'smile',
            path: '/accountsettings',
            component: './AccountSettings',
          },
          {
            component: './404',
          },
        ],
      },
      {
        component: './404',
      },
    ],
  },
  {
    component: './404',
  },
];
